﻿<UserControl x:Class="Majoopic.WPFClient.Views.ImagesViewer"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d" 
             d:DesignHeight="300" d:DesignWidth="300">
    <Grid>
        <ListBox Height="Auto" ItemsSource="{Binding Path=Images, UpdateSourceTrigger=PropertyChanged}" HorizontalAlignment="Stretch" Name="lbImages" VerticalAlignment="Stretch" Width="Auto">
            <ListBox.ItemTemplate>
                <DataTemplate>
                    <WrapPanel HorizontalAlignment="Stretch" Width="Auto" Height="Auto">
                        <Image Source="{Binding Path=Thumbnail,Converter={StaticResource convNullImage}}" Width="100" Height="100" /> 
                        <!--<Image Source="Resources/jpeg_file.png" Width="100" Height="100" /> -->
                        <Label Width="Auto" Content="{Binding Path=ImageInfo.FileName}" />
                    </WrapPanel>
                </DataTemplate>
            </ListBox.ItemTemplate>
        </ListBox>
    </Grid>
</UserControl>
